package com.ruoyi.web.service.warning;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.ruoyi.web.domain.warning.WarningInsectRecord;
import com.ruoyi.web.pojo.request.warning.WarningInsectRecordRequest;
import com.ruoyi.web.pojo.request.warning.WarningRecordCountByDayRequest;
import com.ruoyi.web.pojo.vo.warning.HomeWarningStatisticsVo;
import com.ruoyi.web.pojo.vo.warning.WarningRecordCountByDayVO;
import com.ruoyi.web.pojo.vo.warning.WarningRecordCountVO;

import java.util.List;

/**
 * 虫情预警记录 服务类
 * @author fwx  2024-02-06 14:32:38
 */
public interface WarningInsectRecordService extends IService<WarningInsectRecord> {
    /**
    * 新增虫情预警记录
    * @author fwx 2024-2-6 14:32:39
    */
    public void insert(WarningInsectRecord WarningInsectRecord);

    /**
     * @desc  批量新增
     * @author fwx 2024/2/19 17:04
     **/
    public void insertList(List<WarningInsectRecord> records);

    /**
    * 修改虫情预警记录
    * @author fwx 2024-2-6 14:32:39
    */
    public void update(WarningInsectRecord WarningInsectRecord);

    /**
    * 删除虫情预警记录
    * @author fwx 2024-2-6 14:32:39
    */
    public void delete(String id);

    /**
    * 分页查询虫情预警记录
    * @author fwx  2024-2-6 14:32:39
    */
    public void queryPage(IPage<WarningInsectRecord> page);

    /**
     * 分页查询虫情预警记录
     * @author fwx  2024-2-6 14:32:39
     */
    public List<WarningInsectRecord> queryPage(WarningInsectRecordRequest request);

    /**
     * @desc  查询今年某一类型的预警记录
     * @author fwx 2024/2/19 16:29
     **/
    public List<WarningInsectRecord> getByType(Integer warningType);

    /**
     * @desc  查询今年某一类型的预警记录
     * @author fwx 2024/2/19 16:29
     **/
    public List<WarningInsectRecord> getByUserType(Integer warningType);

    /**
     * @desc  得到传感器预警记录的统计
     * @author fwx 2024/2/18 15:12
     **/
    public Long countByDay(String start, String end);

    /**
     * @desc  得到一段时间的预警记录
     * @author fwx 2024/2/18 15:23
     **/
    public List<WarningInsectRecord> getListByDay(String start, String end);

    /**
     * @desc  得到虫情预警记录的统计
     * @author fwx 2024/2/18 14:15
     **/
    public WarningRecordCountVO getInsectRecordCount();

    /**
     * @desc  获取虫情预警记录一段时间内每一天的预警统计
     * @author fwx 2024/2/18 14:28
     **/
    public List<WarningRecordCountByDayVO> getInsectRecordCountByDay(WarningRecordCountByDayRequest request);

    /**
     * @desc  得到虫情和传感器预警的统计
     * @author fwx 2024/2/18 14:11
     **/
    public WarningRecordCountVO getRecordCount();


    /**
     * @desc  获取一段时间内每一天的预警统计
     * @author fwx 2024/2/18 14:12
     **/
    public List<WarningRecordCountByDayVO> getRecordCountByDay(WarningRecordCountByDayRequest request);

    /**
     * @desc  首页-获取右下角的预警统计
     * @author fwx 2024/5/25 15:19
     **/
    public HomeWarningStatisticsVo getHomeWarningStatistics(Integer dateType);

    /**
    * 查询所有虫情预警记录
    * @author fwx 2024-2-6 14:32:39
    */
    public List<WarningInsectRecord> queryAll();

    /**
    * 根据id查询虫情预警记录
    * @author fwx  2024-2-6 14:32:39
    */
    public WarningInsectRecord findById(String id);

}
